﻿import request from '/@/utils/request';
enum Api {
  AddRepair = '/api/repair/add',
  DeleteRepair = '/api/repair/delete',
  UpdateRepair = '/api/repair/update',
  PageRepair = '/api/repair/page',
  DetailRepair = '/api/repair/detail',
}

// 增加报修管理
export const addRepair = (params?: any) =>
	request({
		url: Api.AddRepair,
		method: 'post',
		data: params,
	});

// 删除报修管理
export const deleteRepair = (params?: any) => 
	request({
			url: Api.DeleteRepair,
			method: 'post',
			data: params,
		});

// 编辑报修管理
export const updateRepair = (params?: any) => 
	request({
			url: Api.UpdateRepair,
			method: 'post',
			data: params,
		});

// 分页查询报修管理
export const pageRepair = (params?: any) => 
	request({
			url: Api.PageRepair,
			method: 'post',
			data: params,
		});

// 详情报修管理
export const detailRepair = (id: any) => 
	request({
			url: Api.DetailRepair,
			method: 'get',
			data: { id },
		});


